I just installed the zx NPM package.
I installed it locally and imported it:
import { $ } from 'zx'
(async () => {
await $`mkdir test`
})()
But I'm getting this error:
No "exports" main defined in /home/alex/node/check-image-size/node_modules/zx/package.json
Note: I'm using Node 16.14.
What does this kind of error mean, and how can I fix it?
Dou have the "main" field in your package.json ?
https://docs.npmjs.com/cli/v7/configuring-npm/package-json#main